Field of the Invention
The present disclosure relates to an image processing apparatus, an image processing method, and a storage medium, and is particularly suitable for being used to improve the image quality of images.
Description of the Related Art
A general video content is generated on an assumption that a display apparatus has a dynamic range of about 2000. However, some display apparatuses actually used for viewing have a narrow dynamic range because of performance restrictions. There is a situation where an assumed content view is not achieved because of the degradation of the dynamic range of a display apparatus due to a bright viewing environment or the degradation of the dynamic range of a projector due to re-reflection of spontaneous light from the side of a viewer. In such a situation, the viewer views a content under degraded contrast conditions. Accordingly, tone curve correction processing is performed. However, there is a possibility that the image quality may be degraded by blown-out highlights and blocked-up shadows as side effects resulting from the raised contrast in an intermediate portion through the tone curve correction processing.
Even if the display apparatus has a wide original dynamic range, the dynamic range of the display apparatus decreases when viewing the display apparatus in a bright environment. Accordingly, gamma correction for raising the contrast may be performed according to an ambient illuminance of the display apparatus. Also in this case, the image quality may be degraded by blown-out highlights and blocked-up shadows similar to the case where the tone curve correction processing is performed.
As a technique for avoiding such image quality degradation, a certain technique improves the contrast while expanding many gradation portions on a histogram. Japanese Patent Application Laid-Open No. 2009-17200 discusses a technique for changing a use ratio of a tone curve for raising a luminance and a use ratio of a tone curve for reducing the luminance based on histograms of black and white side sections.
In the technique discussed in Japanese Patent Application Laid-Open No. 2009-17200 in which an entire screen is uniformly corrected for the degradation of the dynamic range of a display apparatus, effects of the improved contrast are effective in some portions and not in other portions. As a technique for improving this situation, there has been proposed a technique for changing contrast correction for each portion. Japanese Patent Application Laid-Open No. 10-293841 discusses a technique for raising the contrast and sharpness along with the increase of difference between the average gradation value of an image and the average gradation value of neighborhood pixels of a target pixel. Japanese Patent Application Laid-Open No. 2005-312008 discusses a technique for changing a coefficient of an unsharp-mask in sharpness processing based on the average gradation value of neighborhood pixels of a target pixel.
However, in the technique discussed in Japanese Patent Application Laid-Open No. 10-293841, although the contrast of pixels having a gradation value largely different from the average gradation value of the entire image is improved, the contrast of pixels having a gradation value close to the average gradation value of the entire image is not improved.
In the technique discussed in Japanese Patent Application Laid-Open No. 2005-312008, if the coefficient of the unsharp-mask is increased, there arises an overshoot in the lightest portion or an undershoot in the darkest portion. As a result, image quality degradation such as blown-out highlights, blocked-up shadows, and an edge shoot occurs.
Using the above-described conventional techniques, it is not easy to restrain image quality degradation when an image wherein a wide dynamic range is assumed is displayed with a narrow dynamic range.